package hzk.codex2016.tree;

public class LCS {
	//https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-tree/
    public TreeNode lowestCommonAncestor(TreeNode root, TreeNode p, TreeNode q) {
    	class S{
    		void dfs(TreeNode n){
    			if (n==null) return;
    			
    			dfs(n.left);
    			dfs(n.right);
    		}
    		
    		TreeNode lcs(TreeNode r,TreeNode p,TreeNode q){
				return q;
    			//lcs(r.left, p, q) lcs(r.right,p,q);
    		}
    	}
		return q;
    	
    }
    
	public static void main(String[] args) {
		// TODO Auto-generated method stub

	}

}
